home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1996 April: Mac OS SDK / Dev.CD Apr 96 SDK / Dev.CD Apr 96 SDK1.toast / Development Kits (Disc 1) / OpenDoc / Sample Code / Sample Editors⁄Viewers / SamplePart (C) / Source / SamplePartStubs.c < prev    next >
Encoding:
Text File  |  1995-12-06  |  14.5 KB  |  450 lines  |  [TEXT/MPS ]

  1. /*------------------------------------------------------------------------------
  2.  
  3.     File:            SamplePartStubs.c
  4.     
  5.     Written by:        Steve Smith and Andrey Dolgachev
  6.     
  7.     Copyright:        © 1995 by Apple Computer, Inc., all rights reserved.
  8.     
  9. ------------------------------------------------------------------------------*/
  10. /*
  11. // Notification that this is a SOM source file
  12. #define SampleCode_SamplePart_Class_Source
  13. // define underscore (_) field names
  14. #define VARIABLE_MACROS
  15.  
  16. #ifndef _COMPILERDEFS_
  17. #include "CompDefs.h"
  18. #endif
  19.  
  20. // -- SamplePart Includes -- 
  21.  
  22. #ifndef SOM_SampleCode_SamplePart_ih
  23. #include <SamplePart.ih>
  24. #endif
  25. */
  26.  
  27. //--------------------------------------------------------------------
  28. // SamplePart__ContainingPartPropertiesUpdated
  29. //--------------------------------------------------------------------
  30.  
  31. SOM_Scope void  SOMLINK SamplePart__ContainingPartPropertiesUpdated(SampleCode_SamplePart *somSelf, Environment *ev,
  32.         ODFrame* frame,
  33.         ODStorageUnit* propertyUnit)
  34. {
  35.     SampleCode_SamplePartMethodDebug("SamplePart","ContainingPartPropertiesUpdated");
  36. }
  37.  
  38. //--------------------------------------------------------------------
  39. // SamplePart__PresentationChanged
  40. //--------------------------------------------------------------------
  41.  
  42. SOM_Scope    void
  43. SOMLINK        SamplePart__PresentationChanged(SampleCode_SamplePart *somSelf,
  44.         Environment *ev,
  45.         ODFrame* frame)
  46. {
  47.     SampleCode_SamplePartMethodDebug("SamplePart","PresentationChanged");
  48. }
  49.  
  50. //--------------------------------------------------------------------
  51. // SamplePart__RedoAction
  52. //--------------------------------------------------------------------
  53.  
  54. SOM_Scope void  SOMLINK SamplePart__RedoAction(SampleCode_SamplePart *somSelf, Environment *ev,
  55.         ODActionData* actionState)
  56. {
  57.     SampleCode_SamplePartMethodDebug("SamplePart","RedoAction");
  58. }
  59.  
  60. //--------------------------------------------------------------------
  61. // SamplePart__RemoveEmbeddedFrame
  62. //--------------------------------------------------------------------
  63.  
  64. SOM_Scope void  SOMLINK SamplePart__RemoveEmbeddedFrame(SampleCode_SamplePart *somSelf, Environment *ev,
  65.         ODFrame* embeddedFrame)
  66. {
  67.      SampleCode_SamplePartMethodDebug("SamplePart","RemoveEmbeddedFrame");
  68. }
  69.  
  70. //--------------------------------------------------------------------
  71. // SamplePart__RequestEmbeddedFrame
  72. //--------------------------------------------------------------------
  73.  
  74. SOM_Scope ODFrame*  SOMLINK SamplePart__RequestEmbeddedFrame(SampleCode_SamplePart *somSelf, Environment *ev,
  75.         ODFrame* containingFrame,
  76.         ODFrame* baseFrame,
  77.         ODShape* frameShape,
  78.         ODPart* embedPart,
  79.         ODTypeToken viewType,
  80.         ODTypeToken presentation,
  81.         ODBoolean isOverlaid)
  82. {
  83.     SampleCode_SamplePartMethodDebug("SamplePart","RequestEmbeddedFrame");
  84.  
  85.     return kODNULL;
  86. }
  87.  
  88. //--------------------------------------------------------------------
  89. // SamplePart__RequestFrameShape
  90. //--------------------------------------------------------------------
  91.  
  92. SOM_Scope ODShape*  SOMLINK SamplePart__RequestFrameShape(SampleCode_SamplePart *somSelf, Environment *ev,
  93.         ODFrame* embeddedFrame,
  94.         ODShape* frameShape)
  95. {
  96.      SampleCode_SamplePartMethodDebug("SamplePart","RequestFrameShape");
  97.  
  98.     return kODNULL;
  99. }
  100.  
  101. //--------------------------------------------------------------------
  102. // SamplePart__RevealFrame
  103. //--------------------------------------------------------------------
  104.  
  105. SOM_Scope ODBoolean  SOMLINK SamplePart__RevealFrame(SampleCode_SamplePart *somSelf, Environment *ev,
  106.         ODFrame* embeddedFrame,
  107.         ODShape* revealShape)
  108. {
  109.     SampleCode_SamplePartMethodDebug("SamplePart","RevealFrame");
  110.  
  111.     return kODFalse;
  112. }
  113.  
  114. //--------------------------------------------------------------------
  115. // SamplePart__RevealLink
  116. //--------------------------------------------------------------------
  117.  
  118. SOM_Scope void  SOMLINK SamplePart__RevealLink(SampleCode_SamplePart *somSelf, Environment *ev,
  119.         ODLinkSource* linkSource)
  120. {
  121.     SampleCode_SamplePartMethodDebug("SamplePart","RevealLink");
  122. }
  123.  
  124. //--------------------------------------------------------------------
  125. // SamplePart__SequenceChanged
  126. //--------------------------------------------------------------------
  127.  
  128. SOM_Scope    void
  129. SOMLINK        SamplePart__SequenceChanged(SampleCode_SamplePart *somSelf,
  130.         Environment *ev,
  131.         ODFrame* frame)
  132. {
  133.     SampleCode_SamplePartMethodDebug("SamplePart","SequenceChanged");
  134. }
  135.  
  136. //--------------------------------------------------------------------
  137. // SamplePart__CanvasChanged
  138. //--------------------------------------------------------------------
  139.  
  140. SOM_Scope    void
  141. SOMLINK        SamplePart__CanvasChanged(SampleCode_SamplePart* somSelf,
  142.         Environment* ev,
  143.         ODFacet* facet)
  144. {
  145.     SampleCode_SamplePartMethodDebug("SamplePart","CanvasChanged");
  146. }
  147.  
  148. //--------------------------------------------------------------------
  149. // SamplePart__CanvasUpdated
  150. //--------------------------------------------------------------------
  151.  
  152. SOM_Scope    void
  153. SOMLINK        SamplePart__CanvasUpdated(SampleCode_SamplePart *somSelf,    
  154.         Environment *ev,
  155.         ODCanvas* canvas)
  156. {
  157.     SampleCode_SamplePartMethodDebug("SamplePart","CanvasUpdated");
  158. }
  159.  
  160. //--------------------------------------------------------------------
  161. // SamplePart__GetPrintResolution
  162. //--------------------------------------------------------------------
  163.  
  164. SOM_Scope    ODULong
  165. SOMLINK        SamplePart__GetPrintResolution(SampleCode_SamplePart *somSelf,
  166.         Environment *ev,
  167.         ODFrame* frame)
  168. {
  169.     SampleCode_SamplePartMethodDebug("SamplePart","GetPrintResolution");
  170.  
  171.     return 72;
  172. }
  173.  
  174. //--------------------------------------------------------------------
  175. // SamplePart__LinkStatusChanged
  176. //--------------------------------------------------------------------
  177.  
  178. SOM_Scope    void
  179. SOMLINK        SamplePart__LinkStatusChanged(SampleCode_SamplePart *somSelf,
  180.         Environment *ev,
  181.         ODFrame* frame)
  182. {
  183.     SampleCode_SamplePartMethodDebug("SamplePart","LinkStatusChanged");
  184. }
  185.  
  186. //--------------------------------------------------------------------
  187. // SamplePart__LinkUpdated
  188. //--------------------------------------------------------------------
  189.  
  190. SOM_Scope void  SOMLINK SamplePart__LinkUpdated(SampleCode_SamplePart *somSelf, Environment *ev,
  191.         ODLink* updatedLink,
  192.         ODUpdateID change)
  193. {
  194.     SampleCode_SamplePartData *somThis = SampleCode_SamplePartGetData(somSelf);
  195.     SampleCode_SamplePartMethodDebug("SamplePart","LinkUpdated");
  196.  
  197.     SampleCode_SamplePart_parent_ODPart_LinkUpdated(somSelf,ev,updatedLink,change);
  198. }
  199.  
  200. //--------------------------------------------------------------------
  201. // SamplePart__Drop
  202. //--------------------------------------------------------------------
  203.  
  204. SOM_Scope ODDropResult  SOMLINK SamplePart__Drop(SampleCode_SamplePart *somSelf, Environment *ev,
  205.         ODDragItemIterator* dropInfo,
  206.         ODFacet* facet,
  207.         ODPoint* where)
  208. {
  209.     SampleCode_SamplePartMethodDebug("SamplePart","Drop");
  210.  
  211.     return kODDropFail;
  212. }
  213.  
  214. //--------------------------------------------------------------------
  215. // SamplePart__DropCompleted
  216. //--------------------------------------------------------------------
  217.  
  218. SOM_Scope void  SOMLINK SamplePart__DropCompleted(SampleCode_SamplePart *somSelf, Environment *ev,
  219.         ODPart* destPart,
  220.         ODDropResult dropResult)
  221. {
  222.     SampleCode_SamplePartMethodDebug("SamplePart","DropCompleted");
  223. }
  224.  
  225. //--------------------------------------------------------------------
  226. // SamplePart__EditInLinkAttempted
  227. //--------------------------------------------------------------------
  228.  
  229. SOM_Scope ODBoolean  SOMLINK SamplePart__EditInLinkAttempted(SampleCode_SamplePart *somSelf, Environment *ev,
  230.         ODFrame* frame)
  231. {
  232.     SampleCode_SamplePartMethodDebug("SamplePart","EditInLinkAttempted");
  233.  
  234.     return kODFalse;
  235. }
  236.  
  237. //--------------------------------------------------------------------
  238. // SamplePart__EmbeddedFrameUpdated
  239. //--------------------------------------------------------------------
  240.  
  241. SOM_Scope void  SOMLINK SamplePart__EmbeddedFrameUpdated(SampleCode_SamplePart *somSelf, Environment *ev,
  242.         ODFrame* frame,
  243.         ODUpdateID change)
  244. {
  245.     SampleCode_SamplePartMethodDebug("SamplePart","EmbeddedFrameUpdated");
  246. }
  247.  
  248. //--------------------------------------------------------------------
  249. // SamplePart__EmbeddedFrameSpec
  250. //--------------------------------------------------------------------
  251.  
  252. SOM_Scope void  SOMLINK SamplePart__EmbeddedFrameSpec(SampleCode_SamplePart *somSelf, Environment *ev,
  253.         ODFrame* embeddedFrame,
  254.         ODObjectSpec* spec)
  255. {
  256.     SampleCode_SamplePartMethodDebug("SamplePart","EmbeddedFrameSpec");
  257. }
  258.  
  259. //--------------------------------------------------------------------
  260. // SamplePart__CreateEmbeddedFramesIterator
  261. //--------------------------------------------------------------------
  262.  
  263. SOM_Scope ODEmbeddedFramesIterator*  SOMLINK SamplePart__CreateEmbeddedFramesIterator(SampleCode_SamplePart *somSelf, Environment *ev,
  264.         ODFrame* frame)
  265. {
  266.     SampleCode_SamplePartMethodDebug("SamplePart","CreateEmbeddedFramesIterator");
  267.  
  268.     return kODNULL;
  269. }
  270.  
  271. //--------------------------------------------------------------------
  272. // SamplePart__CreateLink
  273. //--------------------------------------------------------------------
  274.  
  275. SOM_Scope ODLinkSource*  SOMLINK SamplePart__CreateLink(SampleCode_SamplePart *somSelf, Environment *ev,
  276.         ODByteArray* data)
  277. {
  278.     SampleCode_SamplePartMethodDebug("SamplePart","CreateLink");
  279.  
  280.     return kODNULL;
  281. }
  282.  
  283.  
  284. //--------------------------------------------------------------------
  285. // SamplePart__UndoAction
  286. //--------------------------------------------------------------------
  287.  
  288. SOM_Scope void  SOMLINK SamplePart__UndoAction(SampleCode_SamplePart *somSelf, Environment *ev,
  289.         ODActionData* actionState)
  290. {
  291.     SampleCode_SamplePartMethodDebug("SamplePart","UndoAction");
  292.  
  293. }
  294.  
  295. //--------------------------------------------------------------------
  296. // SamplePart__UsedShapeChanged
  297. //--------------------------------------------------------------------
  298.  
  299. SOM_Scope void  SOMLINK SamplePart__UsedShapeChanged(SampleCode_SamplePart *somSelf, Environment *ev,
  300.         ODFrame* embeddedFrame)
  301. {
  302.     SampleCode_SamplePartMethodDebug("SamplePart","UsedShapeChanged");
  303. }
  304.  
  305. //--------------------------------------------------------------------
  306. // SamplePart__DisposeActionState
  307. //--------------------------------------------------------------------
  308.  
  309. SOM_Scope void  SOMLINK SamplePart__DisposeActionState(SampleCode_SamplePart *somSelf, Environment *ev,
  310.         ODActionData* actionState,
  311.         ODDoneState doneState)
  312. {
  313.     SampleCode_SamplePartMethodDebug("SamplePart","DisposeActionState");
  314. }
  315.  
  316. //--------------------------------------------------------------------
  317. // SamplePart__DragEnter
  318. //--------------------------------------------------------------------
  319.  
  320. SOM_Scope ODDragResult  SOMLINK SamplePart__DragEnter(SampleCode_SamplePart *somSelf, Environment *ev,
  321.         ODDragItemIterator* dragInfo,
  322.         ODFacet* facet,
  323.         ODPoint* where)
  324. {
  325.     SampleCode_SamplePartMethodDebug("SamplePart","DragEnter");
  326.  
  327.     return kODFalse;
  328. }
  329.  
  330. //--------------------------------------------------------------------
  331. // SamplePart__DragLeave
  332. //--------------------------------------------------------------------
  333.  
  334. SOM_Scope void  SOMLINK SamplePart__DragLeave(SampleCode_SamplePart *somSelf, Environment *ev,
  335.         ODFacet* facet,
  336.         ODPoint* where)
  337. {
  338.     SampleCode_SamplePartMethodDebug("SamplePart","DragLeave");
  339. }
  340.  
  341. //--------------------------------------------------------------------
  342. // SamplePart__DragWithin
  343. //--------------------------------------------------------------------
  344.  
  345. SOM_Scope ODDragResult  SOMLINK SamplePart__DragWithin(SampleCode_SamplePart *somSelf, Environment *ev,
  346.         ODDragItemIterator* dragInfo,
  347.         ODFacet* facet,
  348.         ODPoint* where)
  349. {
  350.     SampleCode_SamplePartMethodDebug("SamplePart","DragWithin");
  351.  
  352.     return kODFalse;
  353. }
  354.  
  355. //--------------------------------------------------------------------
  356. // SamplePart__FulfillPromise
  357. //--------------------------------------------------------------------
  358.  
  359. SOM_Scope void  SOMLINK SamplePart__FulfillPromise(SampleCode_SamplePart *somSelf, Environment *ev,
  360.         ODStorageUnitView* promiseSUView)
  361. {
  362.     SampleCode_SamplePartMethodDebug("SamplePart","FulfillPromise");
  363. }
  364.  
  365. //--------------------------------------------------------------------
  366. // SamplePart__AcquireContainingPartProperties
  367. //--------------------------------------------------------------------
  368.  
  369. SOM_Scope ODStorageUnit*  SOMLINK SamplePart__AcquireContainingPartProperties(SampleCode_SamplePart *somSelf, Environment *ev,
  370.         ODFrame* frame)
  371. {
  372.     SampleCode_SamplePartMethodDebug("SamplePart","AcquireContainingPartProperties");
  373.  
  374.     return kODNULL;
  375. }
  376.  
  377. //--------------------------------------------------------------------
  378. // SamplePart__AdjustBorderShape
  379. //--------------------------------------------------------------------
  380.  
  381. SOM_Scope ODShape*  SOMLINK SamplePart__AdjustBorderShape(SampleCode_SamplePart *somSelf, Environment *ev,
  382.         ODFacet* embeddedFacet,
  383.         ODShape* shape)
  384. {
  385.     SampleCode_SamplePartMethodDebug("SamplePart","AdjustBorderShape");
  386.  
  387.     //return (SampleCode_SamplePart_parent_ODPart_AdjustBorderShape(somSelf,ev,embeddedFacet,shape));
  388.     return kODNULL;
  389. }
  390.  
  391. //--------------------------------------------------------------------
  392. // SamplePart__ReleaseExtension
  393. //--------------------------------------------------------------------
  394.  
  395. SOM_Scope void  SOMLINK SamplePart__ReleaseExtension(SampleCode_SamplePart *somSelf, Environment *ev,
  396.         ODExtension* extension)
  397. {
  398.     SampleCode_SamplePartMethodDebug("SamplePart","ReleaseExtension");
  399.  
  400.     SOM_TRY
  401.             // We don't support any extensions, but one of our parent classes might;
  402.         SampleCode_SamplePart_parent_ODPart_ReleaseExtension(somSelf,ev,extension);
  403.     SOM_CATCH_ALL
  404.     SOM_ENDTRY
  405. }
  406.  
  407. //--------------------------------------------------------------------
  408. // SamplePart__AcquireExtension
  409. //--------------------------------------------------------------------
  410.  
  411. SOM_Scope ODExtension*  SOMLINK SamplePart__AcquireExtension(SampleCode_SamplePart *somSelf, Environment *ev,
  412.         ODType extensionName)
  413. {
  414.     ODExtension* extension = kODNULL;
  415.  
  416.      SampleCode_SamplePartMethodDebug("SamplePart","AcquireExtension");
  417.  
  418.     SOM_TRY
  419.         ODVolatile( extension );
  420.         // We don't support any extensions, but one of our parent classes might;
  421.         extension = SampleCode_SamplePart_parent_ODPart_AcquireExtension(somSelf,ev,extensionName);
  422.     SOM_CATCH_ALL
  423.         extension = kODNULL;
  424.     SOM_ENDTRY
  425.  
  426.     return extension;
  427. }
  428.  
  429. //--------------------------------------------------------------------
  430. // SamplePart__HasExtension
  431. //--------------------------------------------------------------------
  432.  
  433. SOM_Scope ODBoolean  SOMLINK SamplePart__HasExtension(SampleCode_SamplePart *somSelf, Environment *ev,
  434.         ODType extensionName)
  435. {
  436.     ODBoolean result;
  437.  
  438.     SampleCode_SamplePartMethodDebug("SamplePart","HasExtension");
  439.  
  440.     SOM_TRY
  441.         ODVolatile( result );
  442.         // We don't support any extensions, but one of our parent classes might;
  443.         result = SampleCode_SamplePart_parent_ODPart_HasExtension(somSelf,ev,extensionName);
  444.     SOM_CATCH_ALL
  445.         result = kODFalse;
  446.     SOM_ENDTRY
  447.  
  448.     return result;
  449. }
  450.